<?php

namespace App\Models;

use Dcat\Admin\Traits\HasDateTimeFormatter;

use Illuminate\Database\Eloquent\Model;

class PrizeUser extends Model
{
	use HasDateTimeFormatter;
    protected $table = 'prize_user';
    protected $fillable = ['user_openid','prize_id','prize_status','sign', 'status','type','created_at','updated_at'];

    public function user()
    {
        return $this->belongsTo(RcUser::class,'user_openid','open_id');
    }

    public function prize()
    {
        return $this->belongsTo(Prize::class);
    }
}
